package com.jeff.tianti.cms.entity;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.jeff.tianti.common.entity.BaseEntity;

import javax.persistence.*;

@Entity
@Table(name = "company")//公司表
@JsonIgnoreProperties(value={"area","hibernateLazyInitializer","handler","fieldHandler"})
public class Company extends BaseEntity {
    @Column(name = "logo")
    private String logo;//公司头像
    @Column(name = "file")
    private String file;//图片file路径
    @Column(name = "uid")
    private String uid;//用户id  关联user表
    @Column(name = "company_name")
    private String companyName;//公司名称
    private String areaId;//工作地址 area表外键
    private Area area;
    @Column(name = "detailed")
    private String detailed;//详细地址
    @Column(name = "company_profile")
    private String companyProfile;//公司简介
    @Column(name = "re_zhao")
    private String reZhao;//热招职位   取最新发布的职位
    @Column(name = "state")
    private String state;//0->讲好  1->面议
    @Column(name = "money_min")
    private String moneyMin;//最低薪资
    @Column(name = "money_max")
    private String moneyMax;//最高薪资

    public String getUid() {
        return uid;
    }

    public void setUid(String uid) {
        this.uid = uid;
    }

    public String getReZhao() {
        return reZhao;
    }

    public void setReZhao(String reZhao) {
        this.reZhao = reZhao;
    }

    public String getState() {
        return state;
    }

    public void setState(String state) {
        this.state = state;
    }

    public String getMoneyMin() {
        return moneyMin;
    }

    public void setMoneyMin(String moneyMin) {
        this.moneyMin = moneyMin;
    }

    public String getMoneyMax() {
        return moneyMax;
    }

    public void setMoneyMax(String moneyMax) {
        this.moneyMax = moneyMax;
    }

    public String getLogo() {
        return logo;
    }

    public void setLogo(String logo) {
        this.logo = logo;
    }

    public String getFile() {
        return file;
    }

    public void setFile(String file) {
        this.file = file;
    }

    public String getCompanyName() {
        return companyName;
    }

    public void setCompanyName(String companyName) {
        this.companyName = companyName;
    }

    @Column(name = "areaId")
    public String getAreaId() {
        return areaId;
    }

    public void setAreaId(String areaId) {
        this.areaId = areaId;
    }

    @ManyToOne(fetch = FetchType.LAZY, optional = false)
    @JoinColumn(name = "areaId",updatable = false,insertable = false)
    public Area getArea() {
        return area;
    }

    public void setArea(Area area) {
        this.area = area;
    }

    public String getDetailed() {
        return detailed;
    }

    public void setDetailed(String detailed) {
        this.detailed = detailed;
    }

    public String getCompanyProfile() {
        return companyProfile;
    }

    public void setCompanyProfile(String companyProfile) {
        this.companyProfile = companyProfile;
    }
}
